﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Empires.CRL.DataContract;

namespace Empires.RAL.Access
{
    public interface ICompanyBaseAccess
    {
        /// <summary>
        /// 获取公司id
        /// </summary>
        /// <param name="copName">公司唯一标识名</param>
        /// <returns></returns>
        int QueryCompanyId(string copName);
        /// <summary>
        /// 获得公司唯一标识名
        /// </summary>
        /// <param name="id">公司id</param>
        /// <returns></returns>
        string QueryCompanyName(int id);
        /// <summary>
        /// 获得公司应用模板的基础路径
        /// </summary>
        /// <param name="id">公司id</param>
        /// <returns></returns>
        string QueryCompanyTempleteBasePath(int id);
        /// <summary>
        /// 获得公司应用模板的基础路径
        /// </summary>
        /// <param name="copName">公司唯一标识名</param>
        /// <returns></returns>
        string QueryCompanyTempleteBasePath(string copName);
        /// <summary>
        /// 更新网站模板
        /// </summary>
        /// <param name="master"></param>
        /// <param name="styleId"></param>
        /// <returns></returns>
        int UpdateCompanyTempleteStyle(string master, int styleId);
        /// <summary>
        /// 获得指定用户的站点名
        /// </summary>
        /// <param name="username"></param>
        /// <returns></returns>
        string GetCompanyNameByMasterName(string username);
        /// <summary>
        /// 获得指定网站的创建者
        /// </summary>
        /// <param name="copname"></param>
        /// <returns></returns>
        string GetMasterNameByCopName(string copname);
        /// <summary>
        /// 获取权限设置
        /// </summary>
        /// <param name="copname"></param>
        /// <param name="username"></param>
        /// <returns></returns>
        List<DefaultDataPack> GetCompanyMemberShip(string copname, string username);

    }
}
